package com.myway.dto.lottery;

import com.myway.dto.lottery.domain.LotteryLuckyStatus;
import org.springframework.util.StringUtils;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

public class DTOLotteryListReport implements Serializable {
	private static final long serialVersionUID = 8247067507184470510L;
	private Long id;
	private Long lotteryUserId;
	private Long etUserId;
	private String loginId;
	private String name;
	private String cellphone;
	private String certificateno;
	private String cardNo;
	private LotteryLuckyStatus luckyStatus;
	private String payStatus;
	private String productName;
	private Date lotteryTime;
	private String depDate;
	private String segments;
	private BigDecimal price = new BigDecimal(0.00);

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Long getLotteryUserId() {
		return lotteryUserId;
	}

	public void setLotteryUserId(Long lotteryUserId) {
		this.lotteryUserId = lotteryUserId;
	}

	public Long getEtUserId() {
		return etUserId;
	}

	public void setEtUserId(Long etUserId) {
		this.etUserId = etUserId;
	}

	public String getLoginId() {
		return loginId;
	}

	public void setLoginId(String loginId) {
		this.loginId = loginId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getCellphone() {
		return cellphone;
	}

	public void setCellphone(String cellphone) {
		this.cellphone = cellphone;
	}

	public String getCertificateno() {
		return certificateno;
	}

	public void setCertificateno(String certificateno) {
		this.certificateno = certificateno;
	}

	public String getCardNo() {
		return cardNo;
	}

	public void setCardNo(String cardNo) {
		this.cardNo = cardNo;
	}

	public LotteryLuckyStatus getLuckyStatus() {
		return luckyStatus;
	}

	public void setLuckyStatus(LotteryLuckyStatus luckyStatus) {
		this.luckyStatus = luckyStatus;
	}

	public Date getLotteryTime() {
		return lotteryTime;
	}

	public void setLotteryTime(Date lotteryTime) {
		this.lotteryTime = lotteryTime;
	}

	public String getProductName() {
		return productName;
	}

	public void setProductName(String productName) {
		this.productName = productName;
	}

	public String getSegments() {
		return segments;
	}

	public void setSegments(String segments) {
		this.segments = segments;
	}

	public String getDepDate() {
		return depDate;
	}

	public void setDepDate(String depDate) {
		this.depDate = depDate;
	}

	public BigDecimal getPrice() {
		return price;
	}

	public void setPrice(BigDecimal price) {
		this.price = price;
	}

	public String getOrgCode() {
		if (StringUtils.hasText(segments)) {
			String[] s = segments.split("/");
			if (s.length == 2) {
				return s[0];
			}
		}
		return "";
	}

	public String getDstCode() {
		if (StringUtils.hasText(segments)) {
			String[] s = segments.split("/");
			if (s.length == 2) {
				return s[1];
			}
		}
		return "";
	}

	public String getPayStatus() {
		return payStatus;
	}

	public void setPayStatus(String payStatus) {
		this.payStatus = payStatus;
	}

}
